package com.joplus.housekeeper.ui.fragment.xmppCustomer;

import android.content.Intent;
import android.os.Parcelable;
import android.view.LayoutInflater;
import android.view.View;
import android.widget.Button;
import android.widget.TextView;

import com.hyphenate.chatuidemo.DemoApplication;
import com.joplus.housekeeper.R;
import com.joplus.housekeeper.base.BaseFragment2;
import com.joplus.housekeeper.bean.MessageAccountListBean;
import com.joplus.housekeeper.bean.UserNew;
import com.joplus.housekeeper.network.RequestHelper;
import com.joplus.housekeeper.network.TextCallback;

import com.joplus.housekeeper.ui.view.timeSelector.TimeSelector;
import com.joplus.housekeeper.utils.StringUtils;
import com.zhy.view.flowlayout.FlowLayout;

import java.text.SimpleDateFormat;

/**
 * Created by zisheng on 2017/9/18.
 */

public class PersonFragment extends BaseFragment2 {
    TextView tvBirthday, tvPhone, tvEmail, tvAddress, tvSex, tv_year, tv_weix, tv_qq, tv_company, tv_income, tv_address;

    @Override
    public View initView(LayoutInflater inflater) {
        return inflater.inflate(R.layout.fragment_customer_person, null);
    }

    @Override
    protected void initFindViewById(View view) {

        tvBirthday = (TextView) view.findViewById(R.id.tv_birthday);
        tvPhone = (TextView) view.findViewById(R.id.tv_phone);
        tvEmail = (TextView) view.findViewById(R.id.tv_email);
        tvAddress = (TextView) view.findViewById(R.id.tv_address);
        tvSex = (TextView) view.findViewById(R.id.tv_sex);
        tv_year = (TextView) view.findViewById(R.id.tv_year);
        tv_weix = (TextView) view.findViewById(R.id.tv_weix);
        tv_qq = (TextView) view.findViewById(R.id.tv_qq);
        tv_company = (TextView) view.findViewById(R.id.tv_company);
        tv_income = (TextView) view.findViewById(R.id.tv_income);
        tv_address = (TextView) view.findViewById(R.id.tv_address);
    }

    @Override
    public void initData() {
        MessageAccountListBean user = getArguments().getParcelable("user");
      /*  if (user!=null) {
            SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd hh-mm");

                StringUtils.setText(tvBirthday, simpleDateFormat.format(user.getBirthday()));


            StringUtils.setText(tvPhone, user.getMobile());
            StringUtils.setText(tvEmail, user.getEmail());
            StringUtils.setText(tvSex, user.getGender().equals("0") ? "女士" : "先生");
        }*/

       /* StringUtils.setText(tv_weix, user.getMobile());
        StringUtils.setText(tvPhone, user.getMobile());
        StringUtils.setText(tvPhone, user.getMobile());*/
    }

    /**
     * 修改称谓
     *
     * @param view
     */
    public void updateSex(View view) {


    }







}
